<template>
	<view>
		<artList :list="list" @viewDetail="viewDetail"></artList>
	</view>
</template>

<script>
	import {getBookList} from "@/common/http.api.js"
	export default {
		data() {
			return {
				list:[],
			}
		},
		onLoad() {
			this.getBookList();
		},
		methods: {
			getBookList(){
				getBookList({ custom: { auth: true }}).then((res) => {
					this.list = res.rows;
				}).catch(() =>{
				})
			},
			viewDetail(e){
				this.$util.navto("book-detail/book-detail" , {bookId:e.id});
			}
		}
	}
</script>

<style>

</style>
